
export default {
  getBookListData () {
    return function (dispatch, getState) {
      fetch('https://www.easy-mock.com/mock/5c381b92b754282ba8185ff7/example/mock')
      .then(res => res.json())
      .then(data => {
        data = data.lists
        //console.log("111111111111111", data.lists)
        localStorage.setItem('movielist', JSON.stringify(data))
        dispatch({
          type: "CHANGE_MOVIE_LIST",
          data
        })
      })
    }
  }
} 